package cn.amebius.util;

import java.io.*;

/**
 * @author 阿伟
 * @date 2023/7/20 22:03
 */
public class InputTestRunnable implements Runnable {
    InputStream inputStream = null;
    public InputTestRunnable(InputStream inputStream) {
        this.inputStream = inputStream;
    }

    @Override
    public void run() {
        try {
            InputStreamReader isr =new InputStreamReader(inputStream,"utf-8");
            BufferedReader br =new BufferedReader(isr);
            while ((br.read())!=-1) {
                System.out.println(br.readLine());
            }
        } catch (Exception e) {
            e.printStackTrace();
        }
    }
}
